<!DOCTYPE html>
<html>
<head>
    <meta name="viewport" content="width=device-width, initial-scale=1, initial-scale=1, minimum-scale=1.0, maximum-scale=1.0, user-scalable=no" />
    <meta name="apple-touch-fullscreen" content="yes" />
    <meta name="apple-mobile-web-app-capable" content="yes" />
    <meta name="apple-mobile-web-app-status-bar-style" content="black" />
    <meta name="format-detection" content="telphone=no, email=no" />
    <meta name="renderer" content="webkit" />
    <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1" />
    <meta name="HandheldFriendly" content="true" />
    <meta name="MobileOptimized" content="480" />
    <meta name="screen-orientation" content="portrait" />
    <meta name="x5-orientation" content="portrait" />
    <title>办理记录详情</title>
</head>
<body>
<div class="page">
    <!-- 头部信息 -->
    <th:block th:include="include :: top"/>
    <div class="center">
        <div class="page-content page-wrap">
            <!-- 左侧导航 -->
            <th:block th:include="include :: left"/>
            <div class="page-wrap-container">

                <div class="claim-apply">
                    <div style="border-bottom:1px dashed #ddd; padding:20px 0;">
                        <!--使用手写板以后在互助协会打印即可，单位不需要打印了<c:if test="${onStep.sort > 10}">
                            <a class="layui-btn layui-btn-normal" href="/hzclaim/hzClaimFront/claimAgreementPrint?id=${hzClaim.id}">打印申请书</a>
                            <a class="layui-btn" href="/hzclaim/hzClaimFront/claimDataPrint?id=${hzClaim.id}">打印申请资料</a>
                        </c:if>-->
                        <a class="layui-btn layui-btn-primary" href="/hzclaim/hzClaimFront/unitClaimData?pageNo=1&pageSize=10">返回列表</a>
                    </div>
                    <div class="page-step">
                        <c:forEach items="${stepList}" var="step" varStatus="status">
                            <c:choose>
                                <c:when test="${onStep.sort > step.sort}">
                                    <span class="complete">${step.name}</span>
                                    <c:if test="${!status.last}"><i class="fa fa-arrow-circle-right complete"></i></c:if>
                                </c:when>
                                <c:when test="${hzClaim.stepid == step.id}">
                                    <span class="current">${step.name}</span>
                                    <c:if test="${!status.last}"><i class="fa fa-arrow-circle-right current"></i></c:if>
                                </c:when>
                                <c:otherwise>
                                    <span>${step.name}</span>
                                    <c:if test="${!status.last}"><i class="fa fa-arrow-circle-right"></i></c:if>
                                </c:otherwise>
                            </c:choose>
                        </c:forEach>
                    </div>
                    <div class="page-info ">
                        <h2>申请信息</h2>
                        <table class="page-table">
                            <tr>
                                <th>申领编号</th>
                                <td>${hzClaim.claimno}</td>
                                <th>所属机构</th>
                                <td>${hzClaim.organizename}</td>
                            </tr>
                            <tr>
                                <th>申领类别</th>
                                <td>${hzClaim.categoryName}</td>
                                <th>有效保障期</th>
                                <td>${startTime} 至 ${endTime}</td>
                            </tr>
                            <tr>
                                <th>职工姓名</th>
                                <td>${hzClaim.person.name}</td>
                                <th>证件号码</th>
                                <td>${hzClaim.person.idCard}</td>
                            </tr>
                            <tr>
                                <th>职工手机</th>
                                <td>${hzClaim.personmobile}</td>
                                <th>职工邮箱</th>
                                <td>${hzClaim.personemail}</td>
                            </tr>
                            <tr>
                                <th>银行名称</th>
                                <td>${hzClaim.bankname}</td>
                                <th>银行卡号</th>
                                <td>${hzClaim.bankcard}</td>
                            </tr>
                            <tr>
                                <th>联系人</th>
                                <td>${hzClaim.contactname}</td>
                                <th>联系手机</th>
                                <td>${hzClaim.contactmobile}</td>
                            </tr>
                            <tr>
                                <th>联系电话</th>
                                <td>${hzClaim.contactphone}</td>
                                <th>联系邮箱</th>
                                <td>${hzClaim.contactemail}</td>
                            </tr>
                            <tr>
                                <th>付款情况</th>
                                <td>
                                    <c:choose>
                                        <c:when test="${hzClaim.payment == 1}">
                                            <span>已到款（${hzClaim.paymentTime}）</span>
                                        </c:when>
                                        <c:otherwise>
                                            <span style="color:red">待打款</span>
                                        </c:otherwise>
                                    </c:choose>
                                </td>
                                <th>申领金额</th>
                                <td>
                                    ${hzClaim.claimamount}
                                </td>
                            </tr>
                            <tr>
                                <th>申请材料</th>
                                <td>
                                    <c:choose>
                                        <c:when test="${hzClaim.archive == 1}">
                                            <span style="color:green">已收到资料</span>
                                        </c:when>
                                        <c:otherwise>
                                            <span style="color:red">待邮寄纸质申请资料</span>
                                        </c:otherwise>
                                    </c:choose>
                                </td>
                            </tr>
                        </table>
                        <h2>申领资料</h2>
                        <table class="page-table">
                            <c:forEach items="${claimFieldInfos}" var="claimFieldInfo">
                                <tr>
                                    <th>${claimFieldInfo.fieldName}</th>
                                    <td>
                                        <c:choose>
                                            <c:when test="${claimFieldInfo.fieldTypes == 3}">
                                                <span> ${claimFieldInfo.valueString}</span>
                                            </c:when>
                                            <c:otherwise>
                                                <span> ${claimFieldInfo.valueEecimal}</span>
                                            </c:otherwise>
                                        </c:choose>
                                    </td>
                                </tr>
                            </c:forEach>
                        </table>

                        <div class="page-form-item">
                            <div class="page-form-label">诊疗方式：</div>
                            <div class="page-form-input">
                                <select class="page-form-select" name="inpatientClinic" val="${hzClaim.inpatientClinic}" disabled="disabled">
                                    <option value="1">住院</option><option value="2">门诊</option>
                                </select>
                            </div>
                        </div>

                        <h2>诊疗医院</h2>
                        <table class="page-table page-table-list invoice-table" style=" min-width:400px ">
                            <tr>
                                <th>医院名称</th>
                                <th>医院等级</th>
                                <th>是否本地</th>
                                <th>住院时间</th>
                            </tr>
                            <c:forEach items="${claimHospitals}" var="claimHospital">
                                <tr>
                                    <td>${claimHospital.hzConfHospital.name}</td>
                                    <td>
                                        <c:if test="${claimHospital.hzConfHospital.grade == 1}">
                                            一级
                                        </c:if>
                                        <c:if test="${claimHospital.hzConfHospital.grade == 2}">
                                            二级
                                        </c:if>
                                        <c:if test="${claimHospital.hzConfHospital.grade == 3}">
                                            三级
                                        </c:if>
                                    </td>
                                    <td>
                                        <c:choose>
                                            <c:when test="${claimHospital.hzConfHospital.islocal == 1}">
                                                是
                                            </c:when>
                                            <c:otherwise>
                                                否
                                            </c:otherwise>
                                        </c:choose>
                                    </td>
                                    <td>${claimHospital.startDate} 至 ${claimHospital.endDate}（${claimHospital.days}天）</td>
                                </tr>
                            </c:forEach>
                        </table>

                        <h2>证明材料</h2>
                        <c:forEach items="${claimFileInfos}" var="claimFileInfo">
                            <div class="claim-apply-file">
                                <h2>${claimFileInfo.fileName}</h2>
                                <div class="claim-apply-file-list claim-apply-file2">
                                    <c:forEach items="${claimFileInfo.claimProveFiles}" var="claimProveFile">
                                        <div class="claim-apply-file-item">
                                            <img src="${claimProveFile.fileurl}" />
                                            <a class="claim-apply-file-btn layui-btn layui-btn-sm" target="_blank"  href="/hzclaim/hzClaimFront/viewImages?fileurl=${claimProveFile.fileurl}">查看</a>
                                        </div>
                                    </c:forEach>
                                </div>
                            </div>
                        </c:forEach>
                    </div>
                </div>

            </div>
        </div>
    </div>
    <!-- 底部信息 -->
    <th:block th:include="include :: footer"/>
</div>

<script type="text/javascript">

    function openImg(fileurl){
        layer.open({
            title: "申请书打印截图",
            area: ['60%','90%'],
            content:"<div style='text-align:center;width: 95%;height: 100%;display: table-cell;vertical-align: middle;'><img style='width: 1050px;height: 700px;' src='"+ fileurl +"'></div>",
        });
    }

</script>

</body>
</html>
